Regular expressions provide a flexible approach to matching text. They can be very simple, such as f.r, which finds any three letter word beginning with f and ending in r. Or it can be very complex, with several parts described in parentheses that are individually evaluated.
By combining small expressions to form larger complex (compound) expressions, you can create very specific search criteria. For example, you can find any word beginning with pre which also ends with ed, such as pretended or presented.
Regular expressions can be used to match text that can vary between occurrences. For example, searching for a particular assignment operation that has been typed with varying amounts of white space, is now possible using regular expressions.
See Also